@php
    $data = getWeb();
@endphp
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>@yield('title',$data['web_company'])</title>
    <meta name="keywords" content="@yield('keyword',$data['web_keyword'])"/>
    <meta name="description" content="@yield('description',$data['web_desc'])"/>
    <link rel="shortcut icon" href="{{asset('static/image/64.ico')}}" type="image/x-icon">
    <link rel="stylesheet" href="{{asset('static/css/main.css')}}">
    <link rel="stylesheet" href="{{asset('static/css/swiper-bundle.css')}}">
    <link rel="stylesheet" href="{{asset('static/css/swiper.min.css')}}">
    <link rel="stylesheet" href="{{asset('static/css/tailwind.css')}}">
    <link rel="stylesheet" href="{{asset('static/css/iconfont.css')}}">
    <link rel="stylesheet" href="{{asset('static/css/aos.css')}}">
</head>
<body>
    <nav class="z-30 relative">
        <div class="pc-nav hidden lg:block">
            <div class="top-nav flex justify-between">
                <div class="top-logo"><a href="/"><img src="/uploads/{{ $data->web_logo }}" alt=""></a></div>
                <div class="top-nav-sub hidden md:block">
                <div class="icons  items-stretch items-center justify-start md:justify-end flex">
                <ul class="top-nav-sub-ul items-center">
                    @foreach( getSub() as $k=>$v)
                       @if($k<=5)
                       <li class="show-top relative"><a  href="{{$v['url']}}" title="{{$v['name']}}">{{$v['name']}}</a>
                       @if($v['sub'])
                           <div class="show-top-div hidden py-3 absolute z-30">
                               <div class="uls w-full h-full border">
                                   <ul class=" w-full flex flex-wrap p-3">
                                   @foreach($v['sub'] as $vv)
                                       <li class="w-full"><a class="text-sm block pb-1" href="{{$vv['url']}}" title="{{$vv['name']}}">{{$vv['name']}}</a></li>
                                   @endforeach 
                                        
                                   </ul>
                               </div>
                           </div>
                        @endif
                       </li>
                       @endif
                    @endforeach   
                        
                    </ul>
                  <a href="https://www.facebook.com/profile.php?id=100093086366479" target="_blank"> <span style="font-size:28px;" class="text-gray-500 cursor-pointer hover:text-black px-1 iconfont icon-facebook"></span></a>
                  <a href="https://www.linkedin.com/company/92640074/admin/feed/posts/" target="_blank"> <span style="font-size:28px;" class="text-gray-500 cursor-pointer hover:text-black px-1 iconfont icon-linkedin"></span></a>
                  <a href="https://www.twitter.com" target="_blank"> <span style="font-size:28px;" class="text-gray-500 cursor-pointer hover:text-black px-1 iconfont icon-tuitetwitter44"></span></a>
                  <a href="https://www.youtube.com/" target="_blank"> <span style="font-size:28px;" class="text-gray-500 cursor-pointer hover:text-black px-1 iconfont icon-youtube"></span></a>
                  <ul class="top-nav-sub-ul items-center">
                       <li class="show-top relative" ><a class="flex"  href="#"><img style="width:25px;" src="{{asset('static/image/zh.png')}}" alt=""><span style="padding-left:5px;">(CN)</span></a>
                           <div class="show-top-div hidden py-3 absolute z-30" style="min-width:110px;left:-22px;">
                               <div class="uls w-full h-full border" >
                                   <ul class=" w-full flex flex-wrap p-3">
                                       <li class="w-full"><a class="text-sm block pb-1 flex" href="//en1.fongwah.com" ><img style="width:25px;" src="{{asset('static/image/en.png')}}" alt=""><span style="padding-left:5px;">(EN)</span></a></li>
                                   </ul>
                               </div>
                           </div>
                       </li>
                    </ul>
                </div>
                </div>
            </div>
            <div class="main-nav py-2 w-full hidden md:block">
                <ul class="flex  relative">
                <!-- <div class=" absolute left-0"><a href="/"><img src="/uploads/{{ $data->web_logo }}" alt=""></a></div> -->
                @foreach( getMenu() as $v )
                    @if(empty($v['sub']))
                    <li class="py-2 px-2 mr-2 nav-li"><a class="text-sm font-semibold" title="{{$v['name']}}" href="{{$v['url']}}">{{$v['name']}}</a></li>
                    @else
                    <li class="py-2 px-2 mr-2 nav-li">
                        <a class="text-sm font-semibold" href="{{$v['url']}}" title="{{$v['name']}}">{{$v['name']}}</a>
                        <div class="main-index absolute w-full h-32 pt-4 hidden left-0 z-30 overflow-hidden">
                            <div class="w-full bg-white h-full relative">
                                <ul class="left-subs p-5">
                                @foreach($v['sub'] as $key=>$vv)
                                    <li class="text-sm font-semibold left-subs-li {{ $key==0?'left-subs-li1 left-subs-li-active':''}}   leading-8 px-2"><a href="{{$vv['url']}}" title="{{$vv['name']}}">{{$vv['name']}}</a>
                                    <div class="left-subs-right left-subs-right-acitve overflow-hidden absolute right-0 top-0 h-full  px-5 py-2">
                                        <div class="sub-titles text-xl font-semibold">{{$vv['name']}}</div>
                                        <div class="sub-preview mt-3 flex">
                                            <div class="sub-preview-left w-2/3">
                                                <div class="sub-preview-content pr-5">
                                                    @if(!empty($vv['sub']))
                                                        <ul class="flex flex-wrap font">
                                                            @foreach($vv['sub'] as $sub)
                                                            <li class="w-1/2 leading-6 text-black font-normal"><a href="{{$sub['url']}}" title="{{$sub['name']}}">{{$sub['name']}}</a></li>
                                                            @endforeach 
                                                        </ul>
                                                    @else
                                                    <div class="desc py-2 text-black font-normal leading-5 pr-8">{{$vv['desc']}}</div>
                                                       <div class="href">
                                                        <a href="{{$vv['url']}}" class="px-3 more font-normal rounded text-black py-2 border">了解更多</a>
                                                       </div>
                                                    @endif
                                                </div>
                                            </div>
                                            <div class="sub-preview-right w-1/3">
                                                <div class="img flex justify-center">
                                                    <img src="{{$vv['img']}}" alt="">
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    </li>
                                @endforeach     
                                </ul>
                            </div>
                        </div>
                    </li>
                    @endif
                @endforeach    
                </ul>
            </div>
        </div>
        <div class="flex lg:hidden justify-between w-full py-2">
            <div class="px-3"><a href="/"><img src="/uploads/{{ $data->web_logo }}" alt=""></a></div>
            <div class="menus px-2"><span class="iconfont icon-caidan" style="font-size: 30px;"></span></div>
        </div>
    </nav>
    <div class="mob-menu w-full h-screen z-50 fixed top-0 overflow-hidden">
        <div class="covers w-full h-full bg-black opacity-30 "></div>
        <div class=" absolute right-0 top-0 w-3/4 bg-white h-full">
            <div class="w-full flex justify-center">
                <a href="" title=""><img src="/uploads/{{ $data->web_logo }}" alt="" srcset=""></a>
            </div>
            <ul class="mt-5">
            @foreach( getMenu() as $v )
                @if(empty($v['sub']))
                <li class=" leading-10  border-b relative"><a class=" pl-4 pr-6" href="{{$v['url']}}"title="{{$v['name']}}" > {{$v['name']}}</a> 
                 </li>
                @else
                <li class=" leading-10  border-b relative">
                    <a class=" pl-4 pr-6" href="{{$v['url']}}"title="{{$v['name']}}" > {{$v['name']}}</a> <span class="block p-3 mob-iconfont iconfont icon-xiangyou absolute -top-3  right-2"></span>
                    <ul class="mb-sub-li ">
                        @foreach($v['sub'] as $vv)
                            <a href="{{$vv['url']}}"title="{{$vv['name']}}"><li class="pl-8">{{$vv['name']}}</li></a>
                        @endforeach
                    </ul>
                </li>
                @endif
                @endforeach
            </ul>
        </div>
    </div>

    <div class="mobs-nav bg-white fixed left-0 z-30 top-0  w-full  h-14 py-1 ">
        <div class="hidden lg:flex">
            <div class="pc-nav">
                <div class="main-nav py-2 w-full hidden md:block">
                <ul class="flex pl-28 relative">
                <a href="" class=" absolute left-0 -top-2"><img src="/uploads/{{ $data->web_logo }}" alt=""></a>
                @foreach( getMenu() as $v )
            
                    @if(empty($v['sub']))
                    <li class="py-2 px-2 mr-2 nav-li"><a class="text-sm font-semibold" title="{{$v['name']}}" href="{{$v['url']}}">{{$v['name']}}</a></li>
                    @else
                    <li class="py-2 px-2 mr-2 nav-li">
                        <a class="text-sm font-semibold" href="{{$v['url']}}" title="{{$v['name']}}">{{$v['name']}}</a>
                        <div class="main-index absolute w-full h-32 pt-4 hidden left-0 z-30 overflow-hidden">
                            <div class="w-full bg-white h-full relative">
                                <ul class="left-subs p-5">
                                @foreach($v['sub'] as $key=>$vv)
                                    <li class="text-sm font-semibold left-subs-li {{ $key==0?'left-subs-li1 left-subs-li-active':''}}  leading-8 px-2"><a href="{{$vv['url']}}" title="{{$vv['name']}}">{{$vv['name']}}</a>
                                    <div class="left-subs-right left-subs-right-acitve overflow-hidden absolute right-0 top-0 h-full  px-5 py-2">
                                        <div class="sub-titles text-xl font-semibold">{{$vv['name']}}</div>
                                        <div class="sub-preview mt-3 flex">
                                            <div class="sub-preview-left w-2/3">
                                                <div class="sub-preview-content pr-5">
                                                    @if(!empty($vv['sub']))
                                                        <ul class="flex flex-wrap font">
                                                            @foreach($vv['sub'] as $sub)
                                                            <li class="w-1/2 leading-6 text-black font-normal"><a href="{{$sub['url']}}" title="{{$sub['name']}}">{{$sub['name']}}</a></li>
                                                            @endforeach 
                                                        </ul>
                                                    @else
                                                    <div class="desc py-2 text-black font-normal leading-5 pr-8">{{$vv['desc']}}</div>
                                                       <div class="href">
                                                        <a href="{{$vv['url']}}" class="px-3 more font-normal rounded text-black py-2 border">了解更多</a>
                                                       </div>
                                                    @endif
                                                </div>
                                            </div>
                                            <div class="sub-preview-right w-1/3">
                                                <div class="img flex justify-center">
                                                    <img src="{{$vv['img']}}" alt="">
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    </li>
                                @endforeach     
                                </ul>
                            </div>
                        </div>
                    </li>
                    @endif
                @endforeach    
                </ul>
                </div>
            </div>
        </div>
        <div class="flex lg:hidden justify-between w-full">
            <div class="px-3"><a href="/"><img src="/uploads/{{ $data->web_logo }}" alt=""></a></div>
            <div class="menus px-2"><span class="iconfont icon-caidan" style="font-size: 30px;"></span></div>
        </div>
    </div>
    @yield('content')
    <div class="footer w-full py-4 md:p-6 lg:p-12">
        <div class="footer-content flex flex-wrap">
             @foreach( getfooter() as $v)
            <div class=" w-1/2 md:w-1/3 lg:w-1/5 mb-5">
                <div class="pr-4">
                    <div class="title mb-2 ">{{$v['name']}}</div>
                    @foreach($v['sub'] as $vv)
                    <a href="{{$vv['url']}}" title="{{$vv['name']}}"><div class="text-sm hover:text-black text-gray-900 leading-6 ">{{$vv['name']}}</div></a>
                    @endforeach
                </div>
            </div>
            @endforeach

            <div class="out-links flex flex-wrap w-full" style="color:#000!important;"><span>友情链接:</span>
                @foreach(explode(",",$data->web_link) as $v)
                    {!! $v !!}
                @endforeach
            </div>
            <div class="footer-other w-full pt-6 flex flex-wrap">
                <div class="bean w-full md:w-1/2 text-sm  items-stretch text-gray-900"> 
                    <div class="w-full py-3"><a href="/" class="text-sm hover:text-black text-gray-900" title="{{ $data->web_copyright }}">{{ $data->web_copyright }}</a>
                    <a href="https://beian.miit.gov.cn/#/Integrated/index"  title="{{ $data->web_beian }}">{{ $data->web_beian }}</a></div> </div>

            </div>
        </div>
    </div>
    <div class="slide z-30">
        <div class="one-slide-item cursor-pointer pt-1">
            <span class="iconfont icon-24gf-phoneBubble flow-tabr-icon absolute  -top-2"></span>
            <div class="slide-info text-white py-2"><a href="tel:{{ $data->web_phone }}" class="pl-3">{{ $data->web_phone }}</a></div>
        </div>
        @if($data->web_wechat!='')
        <div class="one-slide-item cursor-pointer ">
            <span class="iconfont icon-weixin flow-tabr-icon absolute  -top-2"></span>
            <div class="slide-info text-white py-2"><a href="wechat:{{ $data->web_wechat }}" class="pl-3">{{ $data->web_wechat }}</a></div>
        </div>
        @endif
        @if($data->web_qq!='')
        <div class="one-slide-item cursor-pointer">
            <span class="iconfont icon-qq flow-tabr-icon absolute  -top-2"></span>
            <div class="slide-info text-white py-2"><a href="//wpa.qq.com/msgrd?v=3&uin={{ $data->web_qq }}&site=qq&menu=yes&jumpflag=1" class="pl-3">{{ $data->web_qq }}</a></div>
        </div>
        @endif
        @if($data->web_email!='')
        <div class="one-slide-item cursor-pointer">
            <span class="iconfont icon-youxiang1 flow-tabr-icon absolute  -top-2"></span>
            <div class="slide-info text-white py-2"><a href="mailto:{{ $data->web_email }}" class="pl-3">{{ $data->web_email }}</a></div>
        </div>
        @endif
        @if($data->web_skype!='')
        <div class="one-slide-item cursor-pointer">
            <span class="iconfont icon-skype flow-tabr-icon absolute   -top-2"></span>
            <div class="slide-info text-white py-2"><a href="skype:{{ $data->web_skype }}?chat" class="pl-3">{{ $data->web_skype }}</a></div>
        </div>
        @endif
        <div class="one-slide-item cursor-pointer">
            <span class="iconfont  icon-fanhuidingbu1 flow-tabr-icon absolute  -top-2" onclick="$('body,html').animate({ scrollTop: 0 }, 600);"></span>
        </div>
    </div>




</body>
<script src="{{asset('static/js/jquery-1.8.3.min.js')}}"></script>
<script src="{{asset('static/js/swiper-bundle.min.js')}}"></script>
<script src="{{asset('static/js/aos.js')}}"></script>
<script src="{{asset('static/js/conn.js')}}"></script>

</html>